<template>
  <div>
    <ul class="mui-table-view">
      <li class="mui-table-view-cell mui-media">
        <a href="javascript:;">
          <img class="mui-media-object mui-pull-left" src="../../public/images/menu1.png">
          <div class="mui-media-body">
            <h3>笑话：发工资了，回家把钱交给老妈，没想到却遭到老妈的嫌弃</h3>
            <p class="mui-ellipsis">
              <span>发表时间：2019-06-04 11：25：54</span>
              <span>点击：1次</span>
            </p>
          </div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media">
        <a href="javascript:;">
          <img class="mui-media-object mui-pull-left" src="../../public/images/menu1.png">
          <div class="mui-media-body">
            木屋
            <p class="mui-ellipsis">想要这样一间小木屋，夏天挫冰吃瓜，冬天围炉取暖.</p>
          </div>
        </a>
      </li>
      <li class="mui-table-view-cell mui-media">
        <a href="javascript:;">
          <img class="mui-media-object mui-pull-left" src="../../public/images/menu1.png">
          <div class="mui-media-body">
            CBD
            <p class="mui-ellipsis">烤炉模式的城，到黄昏，如同打翻的调色盘一般.</p>
          </div>
        </a>
      </li>
    </ul>
  </div>
</template>

<script>

import axios from "axios";
export default {
  data() {
    return {
      newsList: []
    };
  },
  components: {},
  created() {
    this.getNewsList();
  },
  methods: {
    getNewsList() {

    
      axios
        .get("http://v.juhe.cn/toutiao/index", {
          params: {
            type:'top',
            key:'416921f152f197aecbd0d518937a1132'
          }
        })
        .then(function(response) {
          console.log(response);
        })
        .catch(function(error) {
          console.log(error);
        });
    }
  }
};
</script>

<style lang='scss' scoped>
.mui-media-body {
  & > h3 {
    font-size: 14px;
    width: 100%;
    color: #222222;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
  }
}
.mui-ellipsis {
  display: flex;
  justify-content: space-between;
  & > span {
    font-size: 12px;
    color: #15478b;
  }
}
</style>